Motion estimation (ME) in video coding may be used to improve video compression performance by removing or reducing temporal redundancy among video frames. For encoding an input block, traditional motion estimation may be performed at an encoder within a specified search window in reference frames. This may allow determination of a motion vector to minimize the sum of absolute differences (SAD) between the input block and a reference block. The motion vector (MV) information can then be transmitted to a decoder for motion compensation. The motion vector can be determined for fractional pixel units, and interpolation filters can be used to calculate fractional pixel values.
The motion estimation can be forward, backward or bi-directional, where backward and bi-directional ME may be used in the coding of bi-predictive frames (referred to herein as B frames) while forward ME can be used for both B frames and predicted frames (referred to herein as P-frames). FIG. 1 shows an example of ME for a B frame 110, where MV0 is a forward motion vector obtained by a forward motion search within a search window 160 in a forward reference frame 120. MV1 may be a backward motion vector obtained by a backward motion search within a search window 170 in a backward reference frame 130. In forward ME, the reference block 150 pointed to by MV0 is used as the prediction associated with a current block 140. In backward ME, the reference block 180 pointed to by MV1 may be used as the prediction, in the backwards direction, of the current block 140. In bi-directional ME, the average of the two reference blocks pointed to by MV0 and MV1 may be used as the prediction of the current block 140. Considering that a current block such as block 140 has motion similar to its temporal and spatial neighboring blocks, MV prediction can be performed using the MVs of neighboring blocks to get a predicted MV for a current block. The predicted MV can be used as the search center, and in an entropy coding process, only the difference between the searched MV and the predicted MV is encoded to reduce MV redundancy.